/* eslint-disable no-return-assign */
import { Component, OnInit } from '@angular/core';
import { LoadingService } from '../../service/loading.service';

@Component({
    selector: 'app-loading',
    templateUrl: './loading.component.html',
    styleUrls: ['./loading.component.css']
})
export class LoadingComponent implements OnInit {
    loading = false;

    constructor(private loadingService: LoadingService) {}

    ngOnInit(): void {
        this.loadingService.busy.subscribe((busy) => {
            return (this.loading = busy);
        });
    }
}
